import math
print "Nhap so nguyen N:"
n = None
def is_prime(n):
    import math
    n = abs(n)
    i = 2
    while i <= math.sqrt(n):
        if n % i == 0:
            return False
        i += 1
    return True
def primes(n):
    if(n <= 2): return []
    elif n==3: return [2]
    else:
        rs = [2]
        for x in range(3,n,2):
            if(is_prime(x) == True):
                rs = rs+[x]
        return rs
def printPrimePower(n):
    rs = primes(n)
    for i in primes(n):
        mu = 2
        while (i**mu) < n:
            rs+=[i**mu]
            mu+=1
    for j in reversed(sorted(rs)):
        print j
while not n:
         try:
             n = int(raw_input())
         except ValueError:
             print 'Invalid Number'
print "Cac so prime power nho hon %d la:"% n
printPrimePower(n)
